window.onload=function getusername(){
    document.getElementById("userName").innerHTML = localStorage.getItem("loginName");
    new Vue({
        el: "#order",
        data() {
            return {
                blogs: []
            }
        },
        mounted() {
            let _this = this;
            ajax({
                method: "post",
                url: "../../blog",
                data: {
                    code: 3
                },
                success: function (result) {
                    console.log(result);
                    _this.blogs = result;
                },
                error: function (result) {
                    console.log(result);
                }
            })
        }
    })
}
function login_click(){
    window.location.href="../html/Login.html";
}

function blog_click(e){
    console.log(e);
    localStorage.setItem("page","1");
    localStorage.setItem("domain",e);
    window.location.href="./blog.html";
}

function notify_click() {
    window.location.href="../html/notify.html";
}

function seek_click(){
    let targetField=document.getElementById("seek");
    window.localStorage.setItem("field",targetField.value);
    window.location.href="../html/seek.html";
}

function sort_click(){
    window.location.href="../html/order_thumb.html";
}
